package com.cfs.svcimpl.bz;

import java.util.List;

import com.cfs.dao.bz.DealPersonDao;
import com.cfs.po.bz.DealPerson;
import com.cfs.svc.bz.DealPersonService;
import com.cfs.vo.Condition;

public class DealPersonServiceImpl implements DealPersonService {

	private DealPersonDao dao;
	
	public DealPersonDao getDao() {
		return dao;
	}

	public void setDao(DealPersonDao dao) {
		this.dao = dao;
	}

	public Long add(DealPerson d) {
		Long n = dao.insert(d);
		System.out.println("RETURN DealPerson NUM: " + n + " ID:" + d.getId() );
		return d.getId();
	}

	public int deleteById(Long id) {
		return dao.delete(id);
	}

	public DealPerson get(Long id) {
		return dao.get(id);
	}

	public List<DealPerson> list(Condition c) {
		return dao.list(c);
	}

	public List<DealPerson> listAll() {
		return dao.listAll();
	}

	public Long update(DealPerson d) {
		return dao.update(d);
	}

}
